<template>
  <div class="view-wallet viewport">
    <h2>账户余额</h2>
    <p class="balance"><span>￥</span><strong>{{balance.toFixed(2)}}</strong></p>
    <r-btn primary block class="btn">充值</r-btn>
    <r-btn border primary block class="btn">提现</r-btn>
    <footer>
      <router-link to="/wallet/faq">常见问题</router-link>
      <router-link to="/wallet/logs">余额明细</router-link>
    </footer>
  </div>
</template>
<script>
import RBtn from 'src/components/r-btn'
export default {
  name: 'view-wallet',
  components: {
    RBtn
  },
  data () {
    return {
      balance: 0
    }
  }
}
</script>
<style lang="scss">
  @import "../../styles/index";

  .view-wallet {
    @extend %flex-center;
    flex-direction: column;
    padding: 0 $breath;

    h2 {
      font-size: 14px;
      font-weight: normal;
      margin: auto 0 0;
    }

    .balance {
      font-size: 20px;
      color: $color-head;
      font-weight: bold;
      word-break: keep-all;
      line-height: 45px;
      margin: 15px 0 65px;

      strong {
        font-size: 40px;
        font-weight: 400;
      }
    }

    .btn {
      margin: 12px 0;
    }

    footer {
      margin-top: auto;
      @extend %flex-center;

      a {
        color: $color-primary;
        padding: 0 12px;
        height: 42px;
        line-height: 42px;
      }

      a + a {
        @extend %left-before-thin;

        &::before {
          background-color: #999;
          top: 30%;
          height: 40%;
        }
      }
    }
  }
</style>
